package com.liangxy.news.api;

import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Query;

/**
 * Interface for news API
 */
public interface NewsApiService {
    
    /**
     * Get news list
     * @param key API key
     * @param type News type/category
     * @param page Page number
     * @param pageSize Page size
     * @param isFilter Whether to filter
     * @return NewsResponse
     */
    @GET("toutiao/index")
    Call<NewsResponse> getNewsList(
            @Query("key") String key,
            @Query("type") String type,
            @Query("page") int page,
            @Query("page_size") int pageSize,
            @Query("is_filter") int isFilter
    );
    
    /**
     * Get news detail
     * @param key API key
     * @param uniquekey News ID
     * @return NewsDetailResponse
     */
    @GET("toutiao/content")
    Call<NewsDetailResponse> getNewsDetail(
            @Query("key") String key,
            @Query("uniquekey") String uniquekey
    );
} 